import { Component, _decorator } from "cc";
import PopupHelper from "../helper/PopupHelper";
const {ccclass,property} = _decorator;
@ccclass
export default class UILayer extends Component {
    @property(Component)
    private bt_debug:Component = null
    protected onLoad(): void {
        const urlParams = new URLSearchParams(window.location.search)
        this.bt_debug.node.active=false
        if(window.location.hostname=='ieh5.fenzhidao.com'){
            this.bt_debug.node.active=false
        }else{
            this.bt_debug.node.active=true
        }
    }
    protected onEnable(): void {
        this.bt_debug.node.on('click',this.onShowDebugDialog,this)
    }
    protected onDisable(): void {
        this.bt_debug.node.off('click',this.onShowDebugDialog,this)
    }
    private onShowDebugDialog(){
        const pop=PopupHelper.getInstance()
        pop.openDialog('DebugDialog')
    }
}